package com.yss.sofa.report.engine;

import java.util.HashMap;

public class Context extends HashMap<String, Object>{
	private static final long serialVersionUID = -4816307300819994112L;
	public static final String CONTEXT_KEY_CONNECTION_FACTORY="connection_factory";
	public static final String CONTEXT_KEY_CONSTS="consts";
	public static final String CONTEXT_KEY_DATASET_DATAS="datas";

	@SuppressWarnings("unchecked")
	public <T> T get(String key,Class<T> clazz){
		Object value=get(key);
		if(value==null){
			return null;
		} else {
			return (T)value;
		}
	}
}
